亚洲精品国偷拍自产在线麻豆,国产精品成人观看视频国产奇米,国产成a人亚洲精品无码樱花,无码人妻丰满熟妇精品区

日志樣式

CDP協(xié)議詳解

【概述】
CDP是Cisco Discovery Protocol的縮寫, 它是由思科公司推出的一種私有的二層網(wǎng)絡(luò)協(xié)議,它能夠運行在大部分的思科設(shè)備上面。通過運行 CDP 協(xié)議,思科設(shè)備能夠在與它們直連的設(shè)備之間分享有關(guān)操作系統(tǒng)軟件版本,以及IP地址,硬件平臺等相關(guān)信息。
【用途】
從CDP的字面意思我們可以理解到, 這是一種設(shè)備發(fā)現(xiàn)協(xié)議。 類似的協(xié)議有HP的LLDP(Link Layer Discovery Protocol)還有華為/H3C的 NDP(鄰居發(fā)現(xiàn)協(xié)議)協(xié)議。 CDP是一個二層的網(wǎng)絡(luò)協(xié)議, 默認(rèn)每60 秒向01-00-0C-CC-CC-CC這個組播地址發(fā)送一次通告, 如果在180 秒內(nèi)未獲得先前鄰居設(shè)備的CDP通告,它將清除原來收到的 CDP信息。因為它不依賴任何的三層協(xié)議,透過 CDP 協(xié)議,可以幫助我們解決一些三層錯誤配置的故障,比如錯誤的三層地址等等。
用途一:SNMP協(xié)議通過CDP MIB發(fā)現(xiàn)網(wǎng)絡(luò)拓?fù)?
SNMP 中結(jié)合使用 CDP 管理信息基礎(chǔ) MIB,能使網(wǎng)絡(luò)管理應(yīng)用獲知被管理設(shè)備類型和相鄰設(shè)備的 SNMP 代理地址,并向這些設(shè)備發(fā)送 SNMP 查詢請求。Cisco 發(fā)現(xiàn)協(xié)議支持 CISCO-CDP-MIB。通過返回的響應(yīng)信息,網(wǎng)絡(luò)管理應(yīng)用發(fā)現(xiàn)支持 CDP協(xié)議的網(wǎng)絡(luò)設(shè)備,并依此生成發(fā)現(xiàn)的網(wǎng)絡(luò)拓?fù)洹?/div>
用途二:通過CDP協(xié)議發(fā)現(xiàn)相鄰端口 Duplex不匹配
從CDP Version 2開始, CDP支持傳送端口的Duplex, Native VLAN ID以及VTP Domain等新的 TLV 值。雙工不匹配是一種比較難發(fā)現(xiàn)的網(wǎng)絡(luò)錯誤,它并不會帶來網(wǎng)絡(luò)的中斷但是它會造成某些應(yīng)用性能的急劇下降。
如下例:
SW1--------SW2
在SW1上
SW1#sh int f0/1
FastEthernet0/1 is up, line protocol is up (connected)
Hardware is Fast Ethernet, address is 0013.1ac8.e581 (bia 0013.1ac8.e581)
MTU 1500 bytes, BW 100000 Kbit, DLY 100 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation ARPA, loopback not set
Keepalive set (10 sec)
Full-duplex, 100Mb/s, media type is 10/100BaseTX
input flow-control is off, output flow-control is unsupported
ARP type: ARPA, ARP Timeout 04:00:00
//忽略其他顯示部分
SW1#sh run int f0/1
Building configuration...

Current configuration : 118 bytes
!
interface FastEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
speed 100
duplex full
end
同時交換機有錯誤消息提示
01:04:25: %CDP-4-DUPLEX_MISMATCH: duplex mismatch discovered on
FastEthernet0/1 (not half duplex), with SW2 FastEthernet0/1 (half duplex).
另外一臺交換機上
SW2#sh int f0/1
FastEthernet0/1 is up, line protocol is up (connected)
Hardware is Fast Ethernet, address is 0012.01e8.6101 (bia 0012.01e8.6101)
MTU 1500 bytes, BW 100000 Kbit, DLY 100 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation ARPA, loopback not set
Keepalive set (10 sec)
Half-duplex, 100Mb/s, media type is 10/100BaseTX//忽略其他部分
SW2#sh run int f0/1
Building configuration...

Current configuration : 94 bytes
!
interface FastEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
end
同時交換機上有如下錯誤提示
01:05:43: %CDP-4-DUPLEX_MISMATCH: duplex mismatch discovered on
FastEthernet0/1 (not full duplex), with SW1 FastEthernet0/1 (full duplex).
用途三:通過 CDP協(xié)議發(fā)現(xiàn)相鄰Trunk端口的 Native VLAN ID 不一致
Trunk端口的Native VLAN ID 不一致會導(dǎo)致部分VLAN 通訊出現(xiàn)混亂。
交換機 SW1通過F0/1 與SW2的 F0/2連接。
如下例:
交換機SW1上
SW1#
01:07:51: %CDP-4-NATIVE_VLAN_MISMATCH: Native VLAN mismatch discovered
on FastEthernet0/1 (22), with SW2 FastEthernet0/1 (1).
SW1#sh run int f0/1
Building configuration...
Current configuration : 127 bytes
!
interface FastEthernet0/1
switchport trunk encapsulation dot1q
switchport trunk native vlan 22
switchport mode trunk
end
SW1#show cdp entry *
-------------------------
Device ID: SW2
Entry address(es):
Platform: Cisco WS-C3550-24, Capabilities: Switch IGMP
Interface: FastEthernet0/1, Port ID (outgoing port): FastEthernet0/1
Holdtime : 148 sec
Version :
Cisco IOS Software, C3550 Software (C3550-IPSERVICESK9-M), Version 12.2(35)SE,
RELEASE SOFTWARE (fc2)
Copyright (c) 1986-2006 by Cisco Systems, Inc.
Compiled Sun 03-Dec-06 14:34 by yenanh

advertisement version: 2
Protocol Hello: OUI=0x00000C, Protocol ID=0x0112; payload len=27,
value=00000000FFFFFFFF010221FF000000000000001201E86100FF0000
VTP Management Domain: 'xixi'
Native VLAN: 1 (Mismatch) //對端 Native VLAN ID是 1
Duplex: full
Management address(es):
W1#sh int f0/1 trunk
Port Mode Encapsulation Status Native vlan
Fa0/1 on 802.1q trunking 22
Port Vlans allowed on trunk
Fa0/1 1-4094

Port Vlans allowed and active in management domain
Fa0/1 1,10,20-22,28,33-34,99-100,102,121,323

Port Vlans in spanning tree forwarding state and not pruned
Fa0/1 10,20-21,28,33-34,99-100,102,121,323
用途四:通過 CDP協(xié)議PoE 受電設(shè)備申請 PoE 電源分配
PoE 是Power Over Ethernet的縮寫,也就是我們常說的 Inline Power,為解決一些小型以太網(wǎng)設(shè)備需要單獨供電的而推出的一種集中化供電方式。 利用現(xiàn)有的5 類雙絞線為那些小型的設(shè)備如IP Phone,無線的AP提供電力供應(yīng)。
在PoE 供電系統(tǒng)中,我們把提供電力供應(yīng)的設(shè)備叫 PSE(Power Supply Equipment)接收電力供應(yīng)的叫PD(Powered Device) 。在思科設(shè)備中 PSE 往往是那些中心端點支持 PoE供電的交換機或者交換模塊。而PD 設(shè)備則是那些需要遠(yuǎn)程供電的 IP Phone,無線 AP等等。
對于 PSE 和 PD 設(shè)備都為思科的設(shè)備,思科允許它們之間通過 CDP 交換信息,以期讓PSE 設(shè)備獲得PD 設(shè)備的真實需要的電源供應(yīng)功率。
用途五:協(xié)同ODR工作
ODR是On-Demand Routing的縮寫,直譯可以翻譯成“按需路由” ,我們可以把它看做是基于CDP協(xié)議的一種路由協(xié)議或者把它看做CDP協(xié)議的一種增強功能。在IOS 11.2及以后版本開始支持這個特性。 ODR適合用在那些Hub and Spoke型的網(wǎng)絡(luò)結(jié)構(gòu)中(Hub and Spoke的網(wǎng)絡(luò)拓?fù)浣Y(jié)果我們可以把它理解成一個中心點,多個分支的網(wǎng)絡(luò)拓?fù)洹<蟹种В?。我們只需要在Hub中心路由器上啟用router odr,分支路由器會自動在它的CDP更新中添加有關(guān)它網(wǎng)絡(luò)的TLV信息。
在中心路由器R1 上
R1#config t
R1(config)#router odr //啟動ODR路由。
R1(config-router)#end
R1#sh ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

10.0.0.0/24 is subnetted, 2 subnets
o 10.0.2.0 [160/1] via 192.168.0.2, 00:00:23 //學(xué)習(xí)到的 odr路由
C 10.0.1.0 is directly connected, Loopback0
192.168.1.0/30 is subnetted, 1 subnets
C 192.168.1.0 is directly connected, Serial0/0
在分支路由器R2 上
R2#sh ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route

Gateway of last resort is 192.168.1.1 to network 0.0.0.0

10.0.0.0/24 is subnetted, 1 subnets
C 10.0.2.0 is directly connected, Loopback0
192.168.0.0/30 is subnetted, 1 subnets
C 192.168.0.0 is directly connected, Serial0/0
o* 0.0.0.0/0 [160/1] via 192.168.1.1, 00:00:13 //學(xué)習(xí)到的缺省路由
【報文格式】
CDP協(xié)議是一個二層協(xié)議,它主要依賴某些二層協(xié)議作為它的承載層。
LLC/SNAP: OUI值0x00000C protocol ID 值 0x2000.
Cisco HDLC:Protocol ID 值為0x2000
PPP:Protocol ID 值為0x0207
CDP協(xié)議Decode例子如下:
Frame 1 (386 bytes on wire, 386 bytes captured)
Arrival Time: Oct 27, 2005 17:51:50.282947000
Time delta from previous packet: 0.000000000 seconds
Time since reference or first frame: 0.000000000 seconds
Frame Number: 1
Packet Length: 386 bytes
Capture Length: 386 bytes
Protocols in frame: eth:llc:cdp:data
IEEE 802.3 Ethernet
Destination: CDP/VTP (01:00:0c:cc:cc:cc) //特殊的組播目的地址
Source: Cisco_12:34:56 (00:07:85:12:34:56)
Length: 372
Logical-Link Control
DSAP: SNAP (0xaa) //DSAP和 SSAP 為 0xaa 說明后面跟著的是 SNAP
IG Bit: Individual
SSAP: SNAP (0xaa)
CR Bit: Command
Control field: U, func=UI (0x03)
000. 00.. = Command: Unnumbered Information (0x00)
.... ..11 = Frame type: Unnumbered frame (0x03)
Organization Code: Cisco (0x00000c) //SNAP OUI Field值
PID: CDP (0x2000) //Protocol ID
Cisco Discovery Protocol
Version: 2 //版
TTL: 180 seconds //TTL即為 Holdtime 計數(shù)器時間
Checksum: 0xc2c3
Device ID: LAN354802 //TLV值,設(shè)備 ID
Type: Device ID (0x0001)
Length: 13
Device ID: LAN354802
Addresses //TLV值,地址
Type: Addresses (0x0002)
Length: 17
Number of addresses: 1
IP address: 192.168.2.62
Protocol type: NLPID
Protocol length: 1
Protocol: IP
Address length: 4
IP address: 192.168.2.62
Port ID: FastEthernet0/7 //接口信息
Type: Port ID (0x0003)
Length: 19
Sent through Interface: FastEthernet0/7
Capabilities //支持的功能
Type: Capabilities (0x0004)
Length: 8
Capabilities: 0x0000000a
.... .... .... .... .... .... .... ...0 = Not a Router
.... .... .... .... .... .... .... ..1. = Is a Transparent Bridge
.... .... .... .... .... .... .... .0.. = Not a Source Route Bridge
.... .... .... .... .... .... .... 1... = Is a Switch
.... .... .... .... .... .... ...0 .... = Not a Host
.... .... .... .... .... .... ..0. .... = Not IGMP capable
.... .... .... .... .... .... .0.. .... = Not a Repeater
Software Version //軟件版本信息
Type: Software version (0x0005)
Length: 225
Software Version: Cisco Internetwork Operating System Software
IOS (tm) C3500XL Software (C3500XL-C3H2S-M), Version
12.0(5)WC8, RELEASE SOFTWARE (fc1)
Copyright (c) 1986-2003 by cisco Systems, Inc.
Compiled Thu 19-Jun-03 12:37 by antonino
Platform: cisco WS-C3548-XL //平臺信息
Type: Platform (0x0006)
Length: 21
Platform: cisco WS-C3548-XL
Protocol Hello: Cluster Management
Type: Protocol Hello (0x0008)
Length: 36
OUI: 0x00000C (Cisco)
Protocol ID: 0x0112 (Cluster Management)
Cluster Master IP: 0.0.0.0
UNKNOWN (IP?): 0xFFFFFFFF (255.255.255.255)
Version?: 0x01
Sub Version?: 0x01
Status?: 0x21
UNKNOWN: 0xFF
Cluster Commander MAC: 00:00:00:00:00:00
Switch's MAC: 00:07:85:12:34:56
UNKNOWN: 0xFF
Management VLAN: 100
VTP Management Domain: mynet //VTP管理域信息
Type: VTP Management Domain (0x0009)
Length: 10
VTP Management Domain: mynet
Native VLAN: 105 //NATIVE VLAN ID 信息
Type: Native VLAN (0x000a)
Length: 6
Native VLAN: 105
Duplex: Full
Type: Duplex (0x000b)
Length: 5
Duplex: Full
CDP協(xié)議報文格式

【配置管理】
CDP在思科設(shè)備上的配置管理非常簡單。
(1) 全局下關(guān)閉打開CDP功能
缺省情況下CDP功能是打開的。
全局配置命令 cdp run //全局啟用CDP
no cdp run //全局關(guān)閉CDP
配置范例:
R1#sh cdp //顯示CDP全局配置信息
Global CDP information:
Sending CDP packets every 60 seconds //缺省每 60 秒發(fā)送一次 CDP通告
Sending a holdtime value of 180 seconds //CDP通告保持時間為 180秒
Sending CDPv2 advertisements is enabled //發(fā)送 CDP version 2的通告
R1#config t //進全局配置模式
Enter configuration commands, one per line. End with CNTL/Z.
R1(config)#no cdp run //全局關(guān)閉CDP
R1(config)#exit
R1#
*Mar 1 00:07:45.351: %SYS-5-CONFIG_I: Configured from console by console
R1#sh cdp //這個時候我們再 show相關(guān) CDP信息就會提示 CDP已經(jīng)關(guān)閉
% CDP is not enabled

(2) 端口下關(guān)閉打開CDP功能
我們除了可以在全局狀態(tài)下打開關(guān)閉 CDP 功能,我們也可以根據(jù)情況配置每個端口的
CDP功能的打開關(guān)閉
配置命令:
接口配置模式下 cdp enable //打開接口的 CDP功能
no cdp enable //關(guān)閉接口的 CDP功能
配置范例:
R1#sh cdp interface s0/0 //查看接口的 CDP配置
Serial0/0 is up, line protocol is up //接口狀態(tài)
Encapsulation HDLC //接口封裝格式
Sending CDP packets every 60 seconds //每 60 秒發(fā)送一次 CDP通告
Holdtime is 180 seconds //CDP通告保持時間為 180秒
R1#config t //進全局配置模式
Enter configuration commands, one per line. End with CNTL/Z.
R1(config)#int s0/0 //進接口配置模式
R1(config-if)#no cdp enable //關(guān)閉接口 CDP功能
R1(config-if)#exit
R1(config)#exit
R1#
*Mar 1 00:19:23.443: %SYS-5-CONFIG_I: Configured from console by console
R1#sh cdp interface s0/0 //這個時候我們顯示CDP信息得到空白信息

R1#sh cdp //全局CDP功能還是打開的
Global CDP information:
Sending CDP packets every 60 seconds
Sending a holdtime value of 180 seconds
Sending CDPv2 advertisements is enabled

(3) 調(diào)整CDP計時器配置
缺省情況下發(fā)送計時器為60秒,保持計時器為 180秒
配置命令
全局配置模式下
cdp timer xx //配置發(fā)送計數(shù)器時間為 xx 秒
cdp holdtime xx //配置保持計時器時間為xx 秒
需要說明的有兩點:
第一點:保持計時器時間必須大于發(fā)送計時器時間,建議為至少 2 倍發(fā)送計時器時
間。
第二點:保持計時器是本機發(fā)送出去的 CDP 通告所攜帶,通告接收設(shè)備,本 CDP
通告保持多長時間。而非針對本機收到的CDP通告。
配置范例:

R1#sh cdp //先查看一下當(dāng)前 CDP計時器配置
Global CDP information:
Sending CDP packets every 80 seconds
Sending a holdtime value of 180 seconds
Sending CDPv2 advertisements is enabled
R1#config t //進全局配置模式
Enter configuration commands, one per line. End with CNTL/Z.
R1(config)#cdp timer ? //看看 cdp發(fā)送計時器的配置范圍
<5-254> Rate at which CDP packets are sent (in sec)

R1(config)#cdp timer 90 //配置 CDP發(fā)送計時器為 90 秒
R1(config)#cdp holdtime ? //查看 CDP保持計時器的配置范圍
<10-255> Length of time (in sec) that receiver must keep this packet

R1(config)#cdp holdtime 200 //配置 CDP保持計時器的時間為 200
R1(config)#exit
R1#
*Mar 1 00:37:43.059: %SYS-5-CONFIG_I: Configured from console by console
R1#sh cdp //通過show cdp,發(fā)現(xiàn)計時器配置已經(jīng)更改
Global CDP information:
Sending CDP packets every 90 seconds
Sending a holdtime value of 200 seconds
Sending CDPv2 advertisements is enabled

(4) 允許發(fā)送CDP version2 的通告
缺省情況下思科設(shè)備是允許發(fā)送 CDP version2 的通告。
我們可以通過 no cdp advertise-v2關(guān)閉 CDP version2 通告的發(fā)送。
配置范例:
R1#sh cdp //檢查 cdp全局配置
Global CDP information:
Sending CDP packets every 10 seconds
Sending a holdtime value of 30 seconds
Sending CDPv2 advertisements is enabled
R1#config t //進全局配置模式
Enter configuration commands, one per line. End with CNTL/Z.
R1(config)#no cdp advertise-v2 //關(guān)閉發(fā)送 CDP version通告功能
R1(config)#exit
R1#show cdp //檢查 CDP全局配置,已經(jīng)關(guān)閉
Global CDP information:
Sending CDP packets every 10 seconds
Sending a holdtime value of 30 seconds
Sending CDPv2 advertisements is not enabled
R1#debug cdp packets //打開 CDP報文 debug模式
CDP packet info debugging is on
R1# //發(fā)送 version1的 CDP 報文
*Mar 1 00:52:23.759: CDP-PA: version 1 packet sent out on Serial0/0
對端R2 上
R2#show cdp nei detail //查看 CDP鄰居詳細(xì)信息
-------------------------
Device ID: R1
Entry address(es):
Platform: Cisco 3640, Capabilities: Router Switch IGMP
Interface: Serial0/0, Port ID (outgoing port): Serial0/0
Holdtime : 26 sec

Version :
Cisco IOS Software, 3600 Software (C3640-IS-M), Version 12.4(10a), RELEASE
SOFTW

ARE (fc2)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2006 by Cisco Systems, Inc.
Compiled Wed 11-Oct-06 20:52 by prod_rel_team

advertisement version: 1

(5) CDP相關(guān)show命令
Show cdp //檢查CDP全局配置信息
Show cdp neighbor
使用范例:
R1#show cdp //檢查CDP全局配置信息
Global CDP information:
Sending CDP packets every 10 seconds //發(fā)送時間間隔
Sending a holdtime value of 30 seconds //保持時間間隔
Sending CDPv2 advertisements is not enabled //CDPv2的通告功能
R1#show cdp traffic //顯示 CDP Counters,包含發(fā)送接收到的 CDP報文數(shù)量
CDP counters :
Total packets output: 96, Input: 137 //總共接收發(fā)送多少 CDP報文
Hdr syntax: 0, Chksum error: 0, Encaps failed: 1 //錯誤數(shù)量
No memory: 0, Invalid packet: 0, Fragmented: 0 //錯誤數(shù)量
CDP version 1 advertisements output: 62, Input: 54 //CDPv1的報文數(shù)量
CDP version 2 advertisements output: 34, Input: 83 //CDPv2的報文數(shù)量
R1#clear cdp counters //CDP Counters清零
R1#sh cdp traffic //檢查 CDP Counters清零后的效果
No memory: 0, Invalid packet: 0, Fragmented: 0
CDP version 1 advertisements output: 0, Input: 1
CDP version 2 advertisements output: 0, Input: 1
R1#show cdp nei //顯示設(shè)備發(fā)現(xiàn)的鄰居情況
Capability Codes: R - Router, T - Trans Bridge, B - Source Route Bridge
S - Switch, H - Host, I - IGMP, r - Repeater

Device ID Local Intrfce Holdtme Capability Platform Port ID
R2 Ser 0/0 21 R S I 3640 Ser 0/0
------------------------------------------------------------------------------------------------------
//Device ID 設(shè)備的主機名(Hostname)
//Local Intrfce :本地接口
//Holdtme:CDP通告信息保持多長時間,單位秒
//Capability: R代表是路由器,S支持交換功能,I支持 IGMP多播管理
//Platform:平臺信息
//Port ID:
R1#clear cdp table //清除發(fā)現(xiàn)的鄰居情況
R1#show cdp nei //檢查清除后的效果,所有的鄰居信息被清除
Capability Codes: R - Router, T - Trans Bridge, B - Source Route Bridge
S - Switch, H - Host, I - IGMP, r - Repeater

Device ID Local Intrfce Holdtme Capability Platform Port ID
R1#show cdp neighbors detail //顯示 CDP鄰居詳細(xì)信息
-------------------------
Device ID: R2
Entry address(es):
Platform: Cisco 3640, Capabilities: Router Switch IGMP
Interface: Serial0/0, Port ID (outgoing port): Serial0/0
Holdtime : 19 sec
睿博工作室 .www.netlord.com.cn
第(12)頁
Version :
Cisco IOS Software, 3600 Software (C3640-IS-M), Version 12.4(10a), RELEASE
SOFTW
ARE (fc2)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2006 by Cisco Systems, Inc.
Compiled Wed 11-Oct-06 20:52 by prod_rel_team

advertisement version: 2

R1#show cdp interface //顯示接口的 CDP配置信息
Serial0/0 is up, line protocol is up
Encapsulation HDLC
Sending CDP packets every 10 seconds
Holdtime is 30 seconds
Serial0/1 is up, line protocol is down
Encapsulation HDLC
Sending CDP packets every 10 seconds
Holdtime is 30 seconds
Serial0/2 is up, line protocol is down
Encapsulation HDLC
Sending CDP packets every 10 seconds
Holdtime is 30 seconds
Serial0/3 is up, line protocol is down
Encapsulation HDLC
Sending CDP packets every 10 seconds
Holdtime is 30 seconds
R1#sh cdp interface s0/0 //顯示某個具體接口的 CDP配置信息
Serial0/0 is up, line protocol is up
Encapsulation HDLC
Sending CDP packets every 10 seconds
Holdtime is 30 seconds
R1#show cdp entry ?
* all CDP neighbor entries
WORD Name of CDP neighbor entry
R1#show cdp entry R2 //顯示鄰居 R2 的鄰接信息,結(jié)果和 show cdp nei detail一致
-------------------------
Device ID: R2
Entry address(es):
Platform: Cisco 3640, Capabilities: Router Switch IGMP
Interface: Serial0/0, Port ID (outgoing port): Serial0/0
Holdtime : 17 sec

Version :
Cisco IOS Software, 3600 Software (C3640-IS-M), Version 12.4(10a), RELEASE
SOFTW
ARE (fc2)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2006 by Cisco Systems, Inc.
Compiled Wed 11-Oct-06 20:52 by prod_rel_team

advertisement version: 2

(6) CDP相關(guān)Debug命令
見下例:
R2#debug cdp ?
adjacency CDP neighbor info
events CDP events
ip CDP ip info
packets CDP packet-related information
R2#debug cdp packets //打開 debug CDP報文功能
CDP packet info debugging is on
R2#
*Mar 1 01:16:20.279: CDP-PA: version 2 packet sent out on Serial0/0
*Mar 1 01:16:20.283: CDP-PA: version 1 packet sent out on Serial0/0
*Mar 1 01:16:26.163: CDP-PA: Packet received from R1 on interface Serial0/0
*Mar 1 01:16:26.167: **Entry found in cache**

【補充說明】
(1) 常見的CDP錯誤日志信息

%CDP-4-DUPLEX_MISMATCH : duplex mismatch discovered on [chars] ([chars]), with
[chars] [chars] ([chars]).
解釋:CDP發(fā)現(xiàn)雙工配置不匹配。
建議:修改接口雙工配置,保證它們工作在相同的雙工狀態(tài)下。

%CDP-4-NATIVE_VLAN_MISMATCH : Native VLAN mismatch discovered on [chars]
([dec]), with [chars] [chars] ([dec]).

解釋: CDP發(fā)現(xiàn)某802.1Q Trunk端口 Native VLAN ID 不一致
建議: 將兩端Native VLAN ID 配置修改為一致

(2) CDP Version1和Vesion 2 的區(qū)別
CDP Version1 和 Version2的主要區(qū)別在于 Version2 支持更多 TLV,比如交換機之間的 VVTP Domain,Duplex,Native VLAN ID 等等。這樣極大的擴充了 CDP的功能。
 

主站蜘蛛池模板: 孝昌县| 司法| 仲巴县| 乐安县| 大埔区| 上栗县| 西吉县| 禹城市| 宝应县| 雷山县| 东台市| 类乌齐县| 洞口县| 多伦县| 将乐县| 扶沟县| 长兴县| 鹰潭市| 长宁区| 延寿县| 岐山县| 宜宾市| 常州市| 日喀则市| 田林县| 阿尔山市| 道孚县| 南康市| 万山特区| 西林县| 石泉县| 翁牛特旗| 临澧县| 修武县| 阜新| 巴青县| 比如县| 桑日县| 烟台市| 滁州市| 沈阳市|